import request from '@/utils/http';
/** 角色列表 */
export const roleList = (): Promise<App.RequestTableResult> => {
  return request.get(`role/list`);
};

/** 添加角色 */
export const addRoleApi = (data: any): Promise<App.RequestResult> => {
  return request.post(`role/add`, data);
};

/** 删除角色 */
export const deleteRoleApi = (params: any): Promise<App.RequestResult> => {
  return request.delete(`role/deleted`, { params });
};

/** 修改角色信息 */
export const updateRoleApi = (data: any): Promise<App.RequestResult> => {
  return request.put(`role/update`, data);
};
